#include <iostream>
#include <string>
using namespace std;

class Solution {
public:
    string multiply(string num1, string num2)
    {
        if (num1 == "0" || num2 == "0")
        {
            return "0";
        }
        string s(num1.size() + num2.size(), '0');
        size_t n1 = num1.size();
        size_t n2 = num2.size();
        int offset = 0;
        for (int i = n1 - 1; i >= 0; i--)
        {
            int tmp = num1[i] - '0';
            int index = s.size() - 1 - offset;
            for (int j = n2 - 1; j >= 0; j--)
            {
                int ch = tmp;
                ch = ch * (num2[j] - '0') + (s[index] - '0');
                s[index] = ch % 10 + '0';
                s[index - 1] += (ch / 10);
                index--;
            }
            offset++;
        }
        if (s[0] == '0')
        {
            s.erase(0, 1);
        }
        return s;
    }
};

int main()
{
    Solution s1;
    string t1;
    string t2;
    cin >> t1 >> t2;
    cout << s1.multiply(t1,t2) << endl;
	return 0;
}